using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
 
namespace ca.metaobjects.csogateway.Controls
{
    [DefaultProperty("Name")]
    [ToolboxData("<{0}:CSOImport runat=server></{0}:CSOImport>")]
    public class CSOImport : WebControl
    {
        public CSOImport() : 
            base(HtmlTextWriterTag.Div) { }

        [Bindable(true)]
        [Category("Appearance")]
        [DefaultValue("")]
        [Localizable(true)]
        public string Name
        {
            get
            {
                String s = (String)ViewState["Name"];
                return ((s == null) ? String.Empty : s);
            }

            set
            {
                ViewState["Name"] = value;
            }
        }

        protected override void  CreateChildControls()
        {
            if (!this.Page.ClientScript.IsClientScriptIncludeRegistered(Name))
            {
                this.Page.ClientScript.RegisterClientScriptInclude(Name, "csogateway.axd?Name=" + Name);
            }

            base.CreateChildControls();
        }

        protected override void RenderContents(HtmlTextWriter output)
        {
            
        }

        protected override void Render(HtmlTextWriter writer)
        {
            
        }
    }
}
